# define a sk list and extract two of its elements
g = sk_validate(list(gval=stats::rnorm(4^2), gdim=4, gres=0.5))
g[c('gdim', 'gres')]
# display all the grid data as a vector or a matrix
g[]
matrix(g[], dim(g))
# extract a particular grid point or a subset
g[1]
g[seq(5)]
Run the code above in your browser using DataLab